import { RouteRecordRaw } from "vue-router";
// const getCom = (path: string, base?: string) => {
//   if (base) {
//     return () => import(`../${base}/${path}`);
//   }
//   return () => import(`../views/${path}`);
// };

//定义路由
export const defaultRoutes: RouteRecordRaw[] = [
  {
    path: "/login",
    name: "login",
    component: () => import("@/views/login/login.vue"),
    meta: {
      menuShow: true,
      title: "登录",
    },
  },
  {
    path: "/layout",
    name: "layout",
    component: () => import("@/layouts/layout.vue"),
    redirect: "/home",
    children: [],
  },
];
